package com.syh.jn.scm.infrastructure.repository.model.base.downstream;

import com.syh.core.ddd.infrastructure.repository.model.SuperBusinessModel;
import lombok.*;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.math.BigDecimal;

/**
 * 下游客户商品价格模板明细
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
@Entity
@Table(name = "T_BASE_DOWNSTREAM_PRICE_TMPL_DETAIL")
@EqualsAndHashCode(callSuper = true)
public class DownstreamPriceTmplDetailModel extends SuperBusinessModel {
  /**
   * 对应商品价格模板id
   */
  @Column(name = "TEMPLATE_ID", columnDefinition = "bigint COMMENT '对应商品价格模板id'")
  private Long templateId;
  /**
   * 商品id
   */
  @Column(name = "GOODS_ID", columnDefinition = "bigint COMMENT '商品id'")
  private Long goodsId;
  /**
   * 商品名称
   */
  @Column(name = "GOODS_NAME", columnDefinition = "varchar(100) COMMENT '商品名称'")
  private String goodsName;
  /**
   * 商品编码
   */
  @Column(name = "GOODS_CODE", columnDefinition = "varchar(50) COMMENT '商品编码'")
  private String goodsCode;
  /**
   * 商品条码
   */
  @Column(name = "CODE_BAR", columnDefinition = "varchar(100) COMMENT '商品条码'")
  private String codeBar;
  /**
   * 单位
   */
  @Column(name = "UNITS", columnDefinition = "varchar(50) COMMENT '单位'")
  private String units;
  /**
   * 规格
   */
  @Column(name = "SPEC_NAME", columnDefinition = "varchar(50) COMMENT '规格'")
  private String specName;
  /**
   * 分类id
   */
  @Column(name = "CATEGORY_ID", columnDefinition = "bigint COMMENT '分类id'")
  private Long categoryId;
  /**
   * 所属种类,应用分类的父类目录
   */
  @Column(name = "CATEGORY_CATALOG_CODE", columnDefinition = "varchar(50) COMMENT '所属种类,应用分类的父类目录'", length = 50)
  private String categoryCatalogCode;
  /**
   * 分类名
   */
  @Column(name = "CATEGORY_NAME", columnDefinition = "varchar(50) COMMENT '分类名'")
  private String categoryName;
  /**
   * 单价
   */
  @Column(name = "GOODS_PRICE", columnDefinition = "decimal(19,6) COMMENT '单价'")
  private BigDecimal goodsPrice;
  /**
   * 商品起订量
   */
  @Column(name = "QUANTITY", columnDefinition = "decimal(19,2) COMMENT '商品起订量'")
  private BigDecimal quantity;
  /**
   * 商品最大下单量
   */
  @Column(name = "QUANTITY_MAX", columnDefinition = "decimal(19,2) COMMENT '商品最大下单量'")
  private BigDecimal quantityMax;
  /**
   * 创建时间
   */
  @Column(name = "CREATE_TIME_STAMP", columnDefinition = "bigint COMMENT '创建时间'")
  private Long createTimeStamp;
  /**
   * 修改时间
   */
  @Column(name = "LAST_UPDATE_TIME_STAMP", columnDefinition = "bigint COMMENT '修改时间'")
  private Long lastUpdateTimeStamp;
}
